﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;

namespace Interfleet.SE.UICompiler.Core.YahooJavaScriptCompressor
{
    /// <summary>
    /// Compiler factory for Yahoo Javascript Compressor.
    /// </summary>
    /// <seealso cref="CompierAgent"/>
    /// <seealso cref="Arguments"/>
    /// <seealso cref="CompileOptions"/>
    public class YJCompilerAgentFactory : CompileAgentFactory
    {
        /// <summary>
        /// Returns a <see cref="CompilerAgent"/> for Yahoo Javascript compressor
        /// </summary>
        /// <param name="arguments"></param>
        /// <returns></returns>
        public override CompilerAgent CreateCompilerAgent(Arguments arguments)
        {
            return new YJCompilerAgent(arguments);
        }

        /// <summary>
        /// Creates empty <see cref="Arguments"/> for use with <see cref="YCCompilerAgent"/>
        /// </summary>
        /// <returns>An empty instance of <see cref="YJArguments"/></returns>
        public override Arguments CreateArguments()
        {
            return new YJArguments(); ;
        }

        /// <summary>
        /// Returns compile options for Yahoo javascript compressor.
        /// </summary>
        /// <returns></returns>
        public override CompileOptions GetCompileOptions()
        {
            return new YJCompileOptions();
        }
    }
}
